< Prev(J) / Next(K) > / View :

Filename: /text/sbasic/shared/03010305.xhp

(section: rgb)

RGB Function [Runtime]
RGB 関数 [実行時](hd_id3150792.1)

Returns a long integer color value consisting of red, green, and blue components.
赤 (Red)、緑 (Green)、青 (Blue) のコンポーネントで指定されたロング整数を返します。(par_id3150447.2)

(/section: rgb)

Syntax:
構文:(hd_id3147229.3)

RGB (Red, Green, Blue)
RGB (Red, Green, Blue)(par_id3155132.4)

Return value:
戻り値:(hd_id3156442.5)

Long
ロング整数(par_id3159153.6)

Parameter:
パラメータ:(hd_id3154013.7)

Red: Any integer expression that represents the red component (0-255) of the composite color.
Red:コンポジットカラーの、赤 (Red) コンポーネントを指定する整数表式 (0-255)。(par_id3152597.8)

Green: Any integer expression that represents the green component (0-255) of the composite color.
Green:コンポジットカラーの、緑 (Green) コンポーネントを指定する整数表式 (0-255)。(par_id3146974.9)

Blue: Any integer expression that represents the blue component (0-255) of the composite color.
Blue:コンポジットカラーの、青 (Blue) コンポーネントを指定する整数表式 (0-255)。(par_id3151113.10)

(embed text/sbasic/shared/00000003.xhp#errorcode : linkinfo)

Error Codes

エラーコード(hd_id3152869.37)

(/embed text/sbasic/shared/00000003.xhp#errorcode)

(embed text/sbasic/shared/00000003.xhp#err5 : linkinfo)

5 Invalid procedure call
5 無効なプロシージャー呼び出しです (par_id3150891.41)

(/embed text/sbasic/shared/00000003.xhp#err5)

Example:
例:(hd_id3147435.11)

Sub ExampleColor
Sub ExampleColor(par_id3156283.12)

Dim lVar As Long
Dim lVar As Long(par_id3149582.13)

lVar = rgb(128,0,200)
lVar = rgb(128,0,200)(par_id3150417.14)

msgbox "The color " & lVar & " consists of:" & Chr(13) &_
msgbox "The color " & lVar & " consists of:" & Chr(13) &_(par_id3145647.15)

"red= " & red(lVar) & Chr(13)&_
"red= " & red(lVar) & Chr(13)&_(par_id3154491.16)

"green= " & green(lVar) & Chr(13)&_
"green= " & green(lVar) & Chr(13)&_(par_id3149401.17)

"blue= " & blue(lVar) & Chr(13) , 64,"colors"
"blue= " & blue(lVar) & Chr(13) , 64,"colors"(par_id3150716.18)

end sub
end sub(par_id3150752.19)


< Prev / Next >